﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="goodList.aspx.cs" Inherits="Newsell.goodList" %>
<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head runat="server">
    <title></title>
    <link href="style/sellframe.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="formcheck" runat="server">
    <asp:ScriptManager ID="ScrMgoodList" runat="server">
    </asp:ScriptManager>
    <asp:UpdatePanel ID="UpPgoodList" runat="server">
    <ContentTemplate>
        <asp:Repeater ID="RepGoodList" runat="server" 
            onitemcommand="RepGoodList_ItemCommand">
            <ItemTemplate>
                <div class="onsellShow clearfix">
                    <div class="onsellTitle">
                        <h3>
                            <asp:Label ID="LabTitle" runat="server" Text='<%# Eval("Title").ToString().Length > 24 ? Eval("Title").ToString().Substring(0, 24) + "..." : Eval("Title").ToString() %>'></asp:Label></h3>
                            <div>
                            <asp:LinkButton ID="selgoodCommit" runat="server" CommandName="insert" CommandArgument='<%# Eval("NumIid") %>'>发布这个商品</asp:LinkButton>
                            </div>
                    </div>
                 </div>

                <div class="onsellDetail">
                                    <div class="imgField" id="imgparent">
                                        <asp:Image ID="imgImgurl" CssClass="imgcss" runat="server" ImageUrl='<%# Eval("PicUrl") %>' />
                                      </div>

                                    <div class="disCount">
                                     <div class="disInfo">
                                        <label class="disMsg">此商品还未设置打折信息</label>
                                        <a runat="server" ID="disOF" class="disOnOff" onclick='SetPromotion(this)'>设置优惠</a>
                                         <asp:HiddenField ID="setPromo" runat="server" Value="0" />
                                      </div>

                                     <div class="disDetail hidden"><div>
                                        <asp:DropDownList ID="disType" CssClass="disType" runat="server" 
                                            EnableTheming="False" ToolTip="优惠方式" AutoPostBack="False">
                                            <asp:ListItem Value="DISCOUNT">折扣：</asp:ListItem>
                                            <asp:ListItem Value="PRICE">优惠价：</asp:ListItem>
                                        </asp:DropDownList>
                                         <asp:DropDownList ID="disValue2" CssClass="disValue" runat="server">
                                         </asp:DropDownList>
                                        <asp:TextBox ID="disValue" CssClass="disValue hidden" runat="server" Text="请输入优惠价格！" 
                                             EnableTheming="False" MaxLength="8" TextMode="SingleLine" 
                                            Wrap="False" ToolTip="折扣率，打折请输入X.X，优惠价请直接输入价格" Width="100px" onfocus="if(this.value=='请输入优惠价格！'){this.value='';}" onKeyPress="if((event.keyCode<48 || event.keyCode>57) && event.keyCode!=46 || /\.\d\d$/.test(value))event.returnValue=false" ></asp:TextBox>
                                        <asp:DropDownList ID="disData" CssClass="disData" runat="server" 
                                            EnableTheming="False" ToolTip="优惠时间">
                                            <asp:ListItem Value="6">6小时</asp:ListItem>
                                            <asp:ListItem Value="12">12小时</asp:ListItem>
                                            <asp:ListItem Value="18">18小时</asp:ListItem>
                                            <asp:ListItem Value="24">24小时</asp:ListItem>
                                        </asp:DropDownList></div>
                                        <a class="disCommit" onclick="return false;">确定</a>
                                      </div>
                                    </div>
                                    <div class="textField">
                                        <asp:Label ID="lablePrice" runat="server" Text='<%#  "<strong class=pricearea>" + Eval("Price") + "</strong>" %>'></asp:Label>
                                        <asp:Label ID="lableNum" runat="server" Text='<%# "库存：" + Eval("num")%>'></asp:Label>
                                        <asp:Label ID="lableValidThru" runat="server" Text='<%# "有效期：" + Eval("ValidThru") + "天"%>'></asp:Label>
                                     </div>

                                 </div>
            </ItemTemplate>
            <FooterTemplate>
                <asp:Panel ID="Panel1" runat="server" CssClass="onsellShow clearfix" Visible='<%#RepGoodList.Items.Count == 0%>'><div class="textArea">
                        <div id="nogoods" style=""><dl><dt>没有查询到商品！可能由于以下原因造成：</dt><dd>您还没有在淘宝网上开店！</dd><dd>您店铺中此类目下暂时没有商品处于出售中！</dd></dl></div>
                </div></asp:Panel>
            </FooterTemplate>
        </asp:Repeater>
        <webdiyer:AspNetPager ID="goodListPgr" runat="server" 
        CurrentPageButtonPosition="End" 
        CustomInfoHTML="共%PageCount%页，当前为第%CurrentPageIndex%页" FirstPageText="首页" 
        LastPageText="尾页" NextPageText="后页" onpagechanged="grpager_PageChanged" 
        PageIndexBoxType="TextBox" PageSize="6" PrevPageText="前页" 
        ShowCustomInfoSection="Left" ShowPageIndexBox="Never" SubmitButtonText="Go" 
        TextAfterPageIndexBox="页" TextBeforePageIndexBox="转到" 
        NumericButtonCount="4" CssClass="pagertext" Height="10px" Wrap="False" 
            LayoutType="Div"></webdiyer:AspNetPager>
    </ContentTemplate>
    <Triggers>
        <asp:AsyncPostBackTrigger ControlID="goodListPgr" EventName="PageChanged" />
        <asp:AsyncPostBackTrigger ControlID="RepGoodList" EventName="ItemCommand" />
    </Triggers>
    </asp:UpdatePanel>
    </form>
</body>
</html>
